package com.cqw.controller;

import com.cqw.annotation.Log;
import com.cqw.domain.Area;
import com.cqw.service.AreaService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author: caoqingwen
 * @CreateTime: 2021-04-15 16:15
 * @Description:
 */
@RestController
@RequestMapping("/area")
@Slf4j
@Api(tags = "区域接口")
public class AreaController {


    @Autowired
    private AreaService areaService;


    @GetMapping("/list")
    @ApiOperation(value = "查询所有区域")
    @Log(title = "测试")
    public List<Area> list(String name,Integer age) {
        return areaService.getAreaList();
    }


}
